﻿using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Smart.Admin.Domain.Model.Request.Employee
{
    public class CreateEmployeeRequest
    {

        /// <summary>
        /// 登录帐号
        /// </summary>
        [Required(ErrorMessage = "登录帐号必填")]
        public string Account
        {
            get;
            set;
        }

        /// <summary>
        /// 部门id
        /// </summary>
        public int DepartmentId
        {
            get;
            set;
        }


        /// <summary>
        /// 员工名称
        /// </summary>
        [Required(ErrorMessage = "员工名称必填")]
        public string Name
        {
            get;
            set;
        }

        /// <summary>
        /// 手机号码
        /// </summary>
        [Required(ErrorMessage = "手机号码必填")]
        public string Phone
        {
            get;
            set;
        }

        /// <summary>
        /// 登录密码
        /// </summary>
        public string Pwd
        {
            get;
            set;
        }

        /// <summary>
        /// 备注
        /// </summary>
        public string Remark
        {
            get;
            set;
        }

        /// <summary>
        /// 状态(0:禁用,1:启用)
        /// </summary>
        [Range(0,1,ErrorMessage = "状态只能为禁用或者启用")]
        public int Status
        {
            get;
            set;
        }

        /// <summary>
        /// 角色
        /// </summary>
        public List<long> RoleIdList
        {
            get;
            set;
        }
    }

    public class UpdateEmployeeRequest : CreateEmployeeRequest
    {
        /// <summary>
        /// 员工编号
        /// </summary>
        public long EmployeeId
        {
            get;
            set;
        }
    }
}
